package graphique;


import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

import javax.swing.JTextField;

import application.EdgeMerge;

public class EdgemergingListener implements ActionListener {

	private JTextField step = null;
	public EdgemergingListener(JTextField edgeMergingStep) {
		this.step=edgeMergingStep;
	}

	@Override
	public void actionPerformed(ActionEvent arg0) {
		Principal.image=EdgeMerge.run(Principal.image,Integer.parseInt(step.getText()));
		Principal.actualiseImage();
	}
}
